﻿using System;
using System.Collections.Generic;
using System.Text;
using Sys = Cosmos.System;
using CosmosHD;

namespace CosmosKernel1
{
    public class Kernel : Sys.Kernel
    {
        protected override void BeforeRun()
        {
            Cosmos.Hardware.PCSpeaker.playSound(1000);
            Cosmos.Hardware.PCSpeaker.beep();
            int trys = 0;
            trys=Init.initialisate.startpc();
            if (trys==1)
            {
                Account.Start.startpc();
                Run();
            }
            else
            {
                Console.WriteLine("WE see problems with your computer He will shitdown");
                times.Wait(5);
                Power.ACPI.Shutdown();

            }
          
        }
        
        protected override void Run()
        {
            
            System.Console.Write("Input: ");
            var input = System.Console.ReadLine();
            System.Console.Write("Text typed: ");
            System.Console.WriteLine(input);
            if (input == "shitdown" || input == "off" || input == "xuy" || input == "sleep" || input == "reboot")
            {
            Power.ACPI.Shutdown();
            }
            else
            {
                AfterRun();
            }
        }
        protected override void AfterRun()
        {
              //Core.Main();
            Cosmos.Hardware.PCSpeaker.playSound(1000);
            Cosmos.Hardware.PCSpeaker.beep();
        infos.disks.Files.init();


            App.Calc.unit();
         
        }
    }
}
